/**
 * 登陆
 */


$(".login").click(function(){
      var inputusr_value = $(".inputUsr").val();
      var inputpwd_value = $(".inputPassword").val();
      console.log(inputpwd_value,inputusr_value)
      $.ajax("http://localhost/php/login.php",
      {data:{
          username:inputusr_value,
          password:inputpwd_value
          
      }})
      .then(function(res){
            console.log(res)
          if(res.state === "success"){
                console.log(123)
              location.assign("./index.html");

          }else if(res.state === "error"){
                console.log(22)
              alert(res.msg)
          }
      })
  })